package com.gxa.learning.core.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * 培训项目实体
 *
 * @Author lirucong
 * @Date 10:46 2021/12/2
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "tb_project")
@ApiModel
public class Project implements Serializable {
    /**
     * 项目编号
     */
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "project_id")
    @ApiModelProperty(name = "projectId", value = "projectId", dataType = "Long")
    private Long projectId;

    /**
     * 项目名称
     */
    @Column(name = "project_name")
    @ApiModelProperty(name = "projectName", value = "projectName", dataType = "String")
    private String projectName;

    /**
     * 项目创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Column(name = "project_time")
    @ApiModelProperty(name = "projectTime", value = "projectTime", dataType = "Date")
    private Date projectTime;

    /**
     * 项目状态(0表示未开始、1表示进行中、2表示已结束)
     */
    @Column(name = "project_status")
    @ApiModelProperty(name = "projectStatus", value = "projectStatus", dataType = "Integer")
    private Integer projectStatus;

    /**
     * 项目负责人
     */
    @Column(name = "project_man")
    @ApiModelProperty(name = "projectMan", value = "projectMan", dataType = "String")
    private String projectMan;

    /**
     * 项目图片
     */
    @Column(name = "project_image")
    @ApiModelProperty(name = "projectImage", value = "projectImage", dataType = "String")
    private String projectImage;
}
